// 请求响应参数（不包含data）
export interface Result {
    code: string;
    msg: string;
}

// 请求响应参数（包含data）
export interface ResultData<T = any> extends Result {
    data: T;
}


// 登录模块
export namespace Login {
    export interface ReqLoginForm {
        username: string;
        password: string;
    }
    export interface ResLogin {
        access_token: string;
    }
    export interface ResAuthButtons {
        [key: string]: string[];
    }
}

// 收藏模块
export namespace Collect {
    export interface ResCollect {
        title: string,
        href: string
    }
}

export namespace Table {

    type Gender = 'male' | 'female';
    export interface ResTable {
        id: number,
        name: string,
        age: number,
        gender: Gender,
        disable: boolean,
        tag: string[],
    }
}